package com.example.foobar.business.service.impl;

import cn.hutool.core.collection.CollectionUtil;
import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.example.foobar.business.service.*;
import com.example.foobar.dao.service.DaQrcodeNewCommerCountDaoService;
import com.example.foobar.dao.service.DaUserChangeRecordDaoService;
import com.example.foobar.dto.DABaseDTO;
import com.example.foobar.entity.*;
import com.example.foobar.param.DaUserChangeRecordPageParam;
import io.geekidea.springbootplus.framework.core.pagination.Paging;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.*;
import java.util.stream.Collectors;

/**
 * 分析系统配置文件 服务实现类
 *
 * @author 郑英奔
 * @since 2021-05-31
 */
@Slf4j
@Service
public class DaQrcodeNewCommerCountServiceImpl implements DaQrcodeNewCommerCountService {

    @Autowired
    private DaQrcodeNewCommerCountDaoService daQrcodeNewCommerCountDaoService;

    @Override
    public boolean saveDaQrcodeNewCommerCount(DaQrcodeNewCommerCount daQrcodeNewCommerCount) {
        return daQrcodeNewCommerCountDaoService.saveDaQrcodeNewCommerCount(daQrcodeNewCommerCount);
    }

    @Override
    public boolean updateDaQrcodeNewCommerCount(DaQrcodeNewCommerCount daQrcodeNewCommerCount) {
        return daQrcodeNewCommerCountDaoService.updateDaQrcodeNewCommerCount(daQrcodeNewCommerCount);
    }

    @Override
    public boolean deleteDaQrcodeNewCommerCount(Long id) {
        return daQrcodeNewCommerCountDaoService.deleteDaQrcodeNewCommerCount(id);
    }

    @Override
    public DaQrcodeNewCommerCount getById(Long id) {
        return daQrcodeNewCommerCountDaoService.getById(id);
    }

    @Override
    public void remove(QueryWrapper<DaQrcodeNewCommerCount> daQrcodeNewCommerCountQueryWrapper) {
        daQrcodeNewCommerCountDaoService.remove(daQrcodeNewCommerCountQueryWrapper);
    }

    @Override
    public void saveBatch(List<DaQrcodeNewCommerCount> daQrcodeNewCommerCountList) {
        daQrcodeNewCommerCountDaoService.saveBatch(daQrcodeNewCommerCountList);
    }

    @Override
    public List<DaQrcodeNewCommerCount> getDaNewCommerByUniacidAndDate(String sceneId, Date baseDate) {
        return daQrcodeNewCommerCountDaoService.getDaNewCommerByUniacidAndDate(sceneId, baseDate);
    }
}
